// pages/my-posts/my-posts.js
Page({
  data: {currentTab: 0, list: []},
  switchTab(e) {
    const index = e.currentTarget.dataset.index
    this.setData({currentTab: index, list: []})
  }
})

